package factoryMethodPattern.ballPen;



import factoryMethodPattern.Pen.PenCore;

/**
 * @program: course
 * @author: lsn
 * @create: 2024-03-24 20:48
 * @description: 圆珠笔的抽象类-构造者
 */
public abstract class BallPen {
    public BallPen() {
        System.out.println("生产了一只装有"+ getPenCore().color + "笔芯的圆珠笔");
    }

    public abstract PenCore getPenCore(); //工厂方法
}

